::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringCardExpireInfo {
    month          {type string minOccurs 1 maxOccurs 1}
    year           {type string minOccurs 1 maxOccurs 1}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringCardInfo {
    number         {type string minOccurs 1 maxOccurs 1}
    name           {type string minOccurs 1 maxOccurs 1}
    expiration     {type RecurringCardExpireInfo minOccurs 1 maxOccurs 1}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringAutobill {
    gateway_name   {type string minOccurs 1 maxOccurs 1}
    card           {type RecurringCardInfo minOccurs 1 maxOccurs 1}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringLine {
    name           {type string minOccurs 0 maxOccurs 1}
    description    {type string minOccurs 0 maxOccurs 1}
    unit_cost      {type string minOccurs 0 maxOccurs 1}
    quantity       {type string minOccurs 0 maxOccurs 1}
    tax1_name      {type string minOccurs 0 maxOccurs 1}
    tax2_name>     {type string minOccurs 0 maxOccurs 1}
    tax1_percent   {type string minOccurs 0 maxOccurs 1}
    tax2_percent   {type string minOccurs 0 maxOccurs 1}
    type           {type string minOccurs 0 maxOccurs 1}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringLineArray {
    line    {type RecurringLine()}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringDetailLine {
    amount         {type string minOccurs 0 maxOccurs 1}
    name           {type string minOccurs 0 maxOccurs 1}
    description    {type string minOccurs 0 maxOccurs 1}
    unit_cost      {type string minOccurs 0 maxOccurs 1}
    quantity       {type string minOccurs 0 maxOccurs 1}
    tax1_name      {type string minOccurs 0 maxOccurs 1}
    tax2_name      {type string minOccurs 0 maxOccurs 1}
    tax1_percent   {type string minOccurs 0 maxOccurs 1}
    tax2_percent   {type string minOccurs 0 maxOccurs 1}
    type           {type string minOccurs 0 maxOccurs 1}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringLineDetailArray {
    line    {type RecurringDetailLine()}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringDefinition {
    client_id       {type string minOccurs 0 maxOccurs 1}
    stopped         {type string minOccurs 0 maxOccurs 1}
    occurrences     {type string minOccurs 0 maxOccurs 1}
    frequency       {type string minOccurs 0 maxOccurs 1}
    send_email      {type string minOccurs 0 maxOccurs 1}
    send_snail_mail {type string minOccurs 0 maxOccurs 1}
    status          {type string minOccurs 0 maxOccurs 1}
    date            {type string minOccurs 0 maxOccurs 1}
    po_number       {type string minOccurs 0 maxOccurs 1}
    discount        {type string minOccurs 0 maxOccurs 1}
    notes           {type string minOccurs 0 maxOccurs 1}
    terms           {type string minOccurs 0 maxOccurs 1}
    first_name      {type string minOccurs 0 maxOccurs 1}
    last_name       {type string minOccurs 0 maxOccurs 1}
    organization    {type string minOccurs 0 maxOccurs 1}
    p_street1       {type string minOccurs 0 maxOccurs 1}
    p_street2       {type string minOccurs 0 maxOccurs 1}
    p_city          {type string minOccurs 0 maxOccurs 1}
    p_state         {type string minOccurs 0 maxOccurs 1}
    p_country       {type string minOccurs 0 maxOccurs 1}
    p_code          {type string minOccurs 0 maxOccurs 1}
    vat_name        {type string minOccurs 0 maxOccurs 1}
    vat_number      {type string minOccurs 0 maxOccurs 1}
    autobill        {type RecurringAutobill minOccurs 0 maxOccurs 1}
    lines           {type RecurringDetailLineArray}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringUpdate {
    recurring_id    {type string minOccurs 1 maxOccurs 1}
    client_id       {type string minOccurs 0 maxOccurs 1}
    stopped         {type string minOccurs 0 maxOccurs 1}
    occurrences     {type string minOccurs 0 maxOccurs 1}
    frequency       {type string minOccurs 0 maxOccurs 1}
    send_email      {type string minOccurs 0 maxOccurs 1}
    send_snail_mail {type string minOccurs 0 maxOccurs 1}
    status          {type string minOccurs 0 maxOccurs 1}
    date            {type string minOccurs 0 maxOccurs 1}
    po_number       {type string minOccurs 0 maxOccurs 1}
    discount        {type string minOccurs 0 maxOccurs 1}
    notes           {type string minOccurs 0 maxOccurs 1}
    terms           {type string minOccurs 0 maxOccurs 1}
    first_name      {type string minOccurs 0 maxOccurs 1}
    last_name       {type string minOccurs 0 maxOccurs 1}
    organization    {type string minOccurs 0 maxOccurs 1}
    p_street1       {type string minOccurs 0 maxOccurs 1}
    p_street2       {type string minOccurs 0 maxOccurs 1}
    p_city          {type string minOccurs 0 maxOccurs 1}
    p_state         {type string minOccurs 0 maxOccurs 1}
    p_country       {type string minOccurs 0 maxOccurs 1}
    p_code          {type string minOccurs 0 maxOccurs 1}
    vat_name        {type string minOccurs 0 maxOccurs 1}
    vat_number      {type string minOccurs 0 maxOccurs 1}
    autobill        {type RecurringAutobill minOccurs 0 maxOccurs 1}
    lines           {type RecurringLineArray}
}

::WS::Utils::ServiceTypeDef Client FreshBookApi RecurringListArray {
    recurring    {type RecurringDefinition()}
}


::WS::Client::DefineRestMethod FreshBookApi recurring recurring.create {
    recurring    {type RecurringDefinition}
} {
    recurring_id {type string}
}

::WS::Client::DefineRestMethod FreshBookApi recurring recurring.update {
    recurring    {type RecurringUpdate}
} {}

::WS::Client::DefineRestMethod FreshBookApi recurring recurring.get {
    recurring_id {type string}
} {
    recurring    {type RecurringDefinition}
}

::WS::Client::DefineRestMethod FreshBookApi recurring recurring.delete {
    recurring_id {type string}
} {}

::WS::Client::DefineRestMethod FreshBookApi recurring recurring.list {
    client_id       {type string minOccurs 0 maxOccurs 1}
    autobill        {type string minOccurs 0 maxOccurs 1}
    page            {type integer minOccurs 0 maxOccurs 1}
    per_page        {type integer minOccurs 0 maxOccurs 1}
    folder          {type integer minOccurs 0 maxOccurs 1}
} {
    recurrings      {type RecurringListArray}
}

::WS::Client::DefineRestMethod FreshBookApi recurring recurring.delete {
    recurring_id    {type string}
    lines           {type RecurringDetailLineArray}
} {}
